#include <catch2/catch.hpp>

#include "solution.hpp"

using namespace solution_224;

TEST_CASE("224. Basic Calculator", "[224]") {

CHECK(Solution().calculate(" 2-1 + 2 ")           == 3);
CHECK(Solution().calculate("(1+(4+5+2)-3)+(6+8)") == 23);
CHECK(Solution().calculate("-2+ 1")               == -1);
CHECK(Solution().calculate("1 + 1")               == 2);
CHECK(Solution().calculate("1+(4+5+2)")           == 12);
CHECK(Solution().calculate("1+(4+5+2)-3")         == 9);
CHECK(Solution().calculate("3-4+(5-(6-2+1))")     == -1);

}
